<#include "../common/_layout.html"/> <@layout>

<div class="panel panel-default">
	<div class="panel-heading">
		<h3 class="panel-title">app ${app.name} env variables:</h3>
	</div>
	<div class="panel-body">
		<table class="table table-striped">
			<thead>
				<tr>
					<th>Key</th>
					<th>Value</th>
					<th>Operation</th>
				</tr>
			</thead>
			<tbody>
				<#list envs as e>
				<tr>
					<td>${e.k}</td>
					<td>${e.v}</td>
					<td><a href="javascript:del_env('${e.id}');">delete</a></td>
				</tr>
				</#list>
			</tbody>
		</table>
		<div class="form-inline">
			<div class="form-group">
				<label for="k">Key:</label> <input type="text" id="k"
					class="form-control" />
			</div>
			<div class="form-group">
				<label for="v">Value:</label> <input type="text" id="v"
					class="form-control" />
			</div>
			<input type="hidden" id="app_id" value="${app.id}">
			<button class="btn btn-primary input-append" onclick="add_env();">Add</button>
		</div>
	</div>
</div>

</@layout>
